package com.mvetc.service;

import java.util.Map;

import com.mvetc.entity.PageInfo;
import com.mvetc.entity.User;

public interface UserService {

	/**
	 * 注册
	 * @param userInfo
	 * @return
	 */
	int register(User user);
	
	
	/**
	 * 验证用户名是否存在
	 * @param userName
	 * @return 存在返回true 不存在返回false
	 */
	boolean existsOfAccountName(String userName);
	

	/**
	 * 登录
	 * @param userName
	 * @param userPassword
	 * @return
	 */
	User login(String userName,String userPassword);
	
	/**
	 * @author linshiqing
	 * @param params
	 * @return
	 */
	PageInfo<User> getBy(Map<String, String> params);
	
	/**
	 * @author linshiqing
	 * @param user
	 * @return
	 */
	int addUser(User user);
	
	/**
	 * @author linshiqing
	 * @param userId
	 * @return
	 */
	int deleteById(String userId);
	
	/**
	 * @author linshiqing
	 * @param user
	 * @return
	 */
	int modify(User user);

}
